package twentyThreePattern.BehaviorPattern11.mediator.section2;

/**
 * 抽象的中介者
 * 
 * @author kongmou
 * @date 2018年3月14日下午2:16:18
 * @since jdk 1.8
 * 
 * @version 1.0
 */
public abstract class AbstractMediator {

	private Purchase purchase;

	private Sale sale;

	private Stock stock;

	// 中介者最重要的方法，叫做事件方法，处理多个对象之间的关系
	public abstract void execute(String str, Object... objects);

	public Purchase getPurchase() {
		return purchase;
	}

	public Sale getSale() {
		return sale;
	}

	public void setPurchase(Purchase purchase) {
		this.purchase = purchase;
	}

	public void setSale(Sale sale) {
		this.sale = sale;
	}

	public Stock getStock() {
		return stock;
	}

	public void setStock(Stock stock) {
		this.stock = stock;
	}

}
